
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
 */
package be.ac.ua.pats.thesisrobotica.device.robotAnalysis;

//~--- non-JDK imports --------------------------------------------------------

import umontreal.iro.lecuyer.charts.XYLineChart;

/**
 * @author Jimmy
 */
public class Grapher {

    /**
     * Outputs a graph to LaTeX format.
     *
     * @param name The graph's name.
     * @param xAxis The x-axis' name.
     * @param yAxis The y-axis' name.
     * @param points The value.
     */
    public static void draw(String name, String xAxis, String yAxis, double[][] points) {
        XYLineChart chart = new XYLineChart(name, xAxis, yAxis, points);
        double[] range = {0,10000,7000,8000};
        chart.setManualRange(range);
        chart.enableGrid(50, 50);
        chart.toLatexFile(name + ".tex", 12, 8);
    }
}
